1. Field of the Invention
The present invention relates to a method of measuring frequency, and more particularly to a method of measuring frequency that is able to obtain a correct frequency reading from a distorted AC power source which includes noise, harmonics or abnormal utility waveforms.
Furthermore, a frequency detector that uses the method is able to use significantly fewer electronic components than are required in conventional frequency detectors.
2. Description of Related Art
In general, an AC power source outputs unstable power with unstable resistance of electronic equipment. Therefore, a switching power supply with angle detection and using a power source, such as utility power generator, etc., detects the frequency of the power that is usually necessary.
With reference to FIG. 5, a conventional first stage (50) of a switching power supply includes a differential circuit (51), an angle detection circuit (52) and a voltage detection circuit (53). Two input ports of the differential circuit (51) connect to the alternating current (AC) power source to compact the AC power. The output terminal of the differential circuit (51) connects to the input terminal of the angle detection circuit (52) to obtain a sample output voltage from the differential circuit (51). Then, the angle detection circuit (52) is able to calculate the frequency of the AC power by calculating the interval of two adjacent quadrilateral-wave falling/rising edges.
When the angle detection circuit (52) outputs continuous pulses, a microprocessor (not shown) determines the frequency of the AC power. However, the angle detection circuits (52) uses a comparator, and when high voltage with noise is input to the comparator, the comparator outputs a signal that includes an error pulse in the normal pulses.
Therefore, the angle detection circuit (52) is sensitive to the noise, harmonics and other abnormal utility waveforms, so that the comparator has no correction frequency detection capability.
With reference to FIG. 6, the difference between another conventional first stage (50a) of a switching power supply and the previously described conventional stable circuit is that the angle detection circuit (52a) consists of a transistor (Q) and resistors (Ra, Rb, Rc). The angle detection circuit is able to transform the output AC signal of the differential circuit (50) to continuous pulses. The angle detection circuit (52a) is able to perform a frequency measurement, but it also has problems such as high noise sensitivity.
To overcome the shortcomings, the present invention provides an improved method of measuring frequency to mitigate and obviate the aforementioned problems.
The objective of the present invention is to provide a method of measuring frequency, wherein the method is able to obtain highly accurate frequency measurement results without using an angle detection circuit.
A further objective of the present invention is to provide a method of measuring frequency that will be lower the manufacturing cost of the equipment.